home *** CD-ROM | disk | FTP | other *** search
/ The 640 MEG Shareware Studio 2 / The 640 Meg Shareware Studio CD-ROM Volume II (Data Express)(1993).ISO / prog / amisl090.zip / AMIS350.TXT < prev    next >
Text File  |  1992-09-12  |  10KB  |  220 lines

  1. INT 2D - ALTERNATE MULTIPLEX INTERRUPT SPECIFICATION (AMIS) [v3.5]
  2.     AH = multiplex number
  3.     AL = function
  4.         00h installation check
  5.         Return: AL = 00h if free
  6.             AL = FFh if multiplex number in use
  7.                 CX = binary version number (CH = major, CL = minor)
  8.                 DX:DI -> signature string (see below) identifying
  9.                     the program using the multiplex number
  10.         01h get entry point
  11.         Return: AL = 00h if all API calls via INT 2D
  12.             AL = FFh if entry point supported
  13.                 DX:BX -> entry point for bypassing interrupt chain
  14.         02h uninstall
  15.             DX:BX = return address for successful uninstall (may be
  16.             ignored by TSR)
  17.         Return: AL = status
  18.                 00h not implemented
  19.                 01h unsuccessful
  20.                 02h can not uninstall yet, will do so when able
  21.                 03h safe to remove, but no resident uninstaller
  22.                     (TSR still enabled)
  23.                     BX = segment of memory block with resident code
  24.                 04h safe to remove, but no resident uninstaller
  25.                     (TSR now disabled)
  26.                     BX = segment of memory block with resident code
  27.                 05h not safe to remove now, try again later
  28.                 FFh successful
  29.             return at DX:BX with AX destroyed if successful and
  30.               TSR honors specific return address
  31.         03h request pop-up
  32.         Return: AL = status
  33.                 00h not implemented or TSR is not a pop-up
  34.                 01h can not pop up at this time, try again later
  35.                 02h can not pop up yet, will do so when able
  36.                 03h already popped up
  37.                 04h unable to pop up, user intervention required
  38.                     BX = standard reason code
  39.                     0000h unknown failure 
  40.                     0001h interrupt chain passes through memory
  41.                           which must be swapped out to pop up
  42.                     0002h swap-in failed
  43.                 CX = application's reason code if nonzero
  44.                 FFh TSR popped up and was exited by user
  45.                 BX = return value
  46.                     0000h no return value
  47.                     0001h TSR unloaded
  48.                     0002h-00FFh reserved
  49.                     0100h-FFFFh application-dependent
  50.         04h determine chained interrupts
  51.             BL = interrupt number (except 2Dh)
  52.         Return: AL = status
  53.                 00h not implemented
  54.                 01h (obsolete) unable to determine
  55.                 02h (obsolete) interrupt hooked
  56.                 03h (obsolete) interrupt hooked, address returned
  57.                     DX:BX -> TSR's interrupt BL handler
  58.                 04h list of hooked interrupts returned
  59.                     DX:BX -> interrupt hook list (see below)
  60.                 FFh interrupt not hooked
  61.         Notes:    since INT 2D is known to be hooked, the resident code
  62.               need not test for BL=2Dh (to minimize its size), and
  63.               the return value is therefore undefined in that case.
  64.             BL is ignored if the TSR returns AL=04h; in that case,
  65.               the caller needs to scan the return list rather than
  66.               making additional calls to this function.  If the
  67.               return is not 00h or 04h, then the caller must cycle
  68.               through the remaining interrupt numbers it wishes to
  69.               check.
  70.             return values 01h thru 03h are disparaged and will be
  71.               removed from the next version of this specification;
  72.               they are included for compatibility with version 3.3,
  73.               though they were probably never used in any
  74.               implementation
  75.         05h get hotkeys
  76.             Return: AL = status
  77.                 00h not implemented
  78.                 FFh supported
  79.                     DX:BX -> hotkey list (see below)
  80.         06h-0Fh reserved for future enhancements
  81.         Return: AL = 00h (not implemented)
  82.         other  application-dependent
  83. Notes:    programs should not use fixed multiplex numbers; rather, a program
  84.       should scan all multiplex numbers from 00h to FFh, remembering the
  85.       first unused multiplex in case the program is not yet installed.
  86.       For multiplex numbers which are in use, the program should compare
  87.       the first 16 bytes of the signature string to determine whether it
  88.       is already installed on that multiplex number.  If not previously
  89.       installed, it should use the first free multiplex number.
  90.     functions other than 00h are not valid unless a program is installed
  91.       on the selected multiplex number
  92.     to be considered fully compliant with version 3.5 of the specification,
  93.       programs must implement at least functions 00h, 02h (no resident
  94.       uninstall code required), and 04h (return value 04h).  TSRs that
  95.       provide hotkeys with which the user can activate them must also
  96.       implement function 05h.  The absolute minimum fully-compliant
  97.       implementation has an overhead of 64 bytes (80 bytes with function
  98.       05h) plus 22 bytes per hooked interrupt (for the interrupt sharing
  99.       protocol header and hook list entry).
  100.     the signature string and description may be used by memory mappers
  101.       to display the installed programs
  102.     users of this proposal should adhere to the IBM interrupt sharing
  103.       protocol (see below), which will permit removal of TSRs in
  104.       arbitrary order and interrupt handler reordering.  All TSRs
  105.       following this proposal should be removable, though they need not
  106.       keep the code for removing themselves resident; it is acceptable
  107.       for a separate program to perform the removal.
  108.     A sample implementation including example TSRs and utility programs
  109.       may be found in a separate package distributed as AMISLnnn.ZIP
  110.       (AMISL090.ZIP as of this writing).
  111.     Please let me know if you choose to follow this proposal.  The
  112.       signature and a list of the private API calls you use would be
  113.       appreciated, as well.
  114. SeeAlso: INT 2F
  115.  
  116. Format of signature string:
  117. Offset    Size    Description
  118.  00h  8 BYTEs    blank-padded manufacturer's name (possibly abbreviated)
  119.  08h  8 BYTEs    blank-padded product name
  120.  10h 64 BYTEs    ASCIZ product description (optional, may be a single 00h)
  121. Note:    it is not necessary to reserve a full 64 bytes for the description,
  122.       just enough to store the actual ASCIZ string
  123.  
  124. Format of interrupt hook list [array]:
  125. Offset    Size    Description
  126.  00h    BYTE    interrupt number (last entry in array is 2Dh)
  127.  01h    WORD    offset within hook list's segment of the interrupt handler
  128.          this will point at the initial short jump of the interrupt
  129.         sharing protocol header (see below)
  130.  
  131. Format of hotkey list:
  132. Offset    Size    Description
  133.  00h    BYTE    type of hotkey checking
  134.          bit 0: checks before chaining INT 09
  135.         bit 1: checks after chaining INT 09
  136.         bit 2: checks before chaining INT 15/AH=4Fh
  137.         bit 3: checks after chaining INT 15/AH=4Fh
  138.         bit 4: checks on INT 16/AH=00h,01h,02h
  139.         bit 5: checks on INT 16/AH=10h,11h,12h
  140.         bits 6,7: reserved (0)
  141.  01h    BYTE    number of hotkeys (may be zero if TSR can disable hotkeys)
  142.  02h 6N BYTEs    array of hotkey definitions
  143.          (one per hotkey, first should be primary hotkey)
  144.          Offset    Size    Description
  145.          00h    BYTE    hotkey scan code (00h/80h if shift states only)
  146.                  hotkey triggers on release if bit 7 set
  147.          01h    WORD    required shift states (see below)
  148.          03h    WORD    disallowed shift states (see below)
  149.          05h    BYTE    flags
  150.                  bit 0: hotkey chained before processing
  151.                 bit 1: hotkey chained after processing
  152.                 bit 2: others should pass through this hotkey
  153.                     so that it can be monitored
  154.                 bit 3: hotkey will not activate if other keys
  155.                     pressed/released before hotkey press is
  156.                     completed
  157.                 bit 4: this key is remapped into some other key
  158.                 bit 5-7: reserved (0)
  159. Notes:    except for bit 7, the shift states correspond exactly to the return
  160.       values from INT 16/AH=12h.  A set bit in the required states word
  161.       indicates that the corresponding shift state must be active when the
  162.       hotkey's scan code is received for the hotkey to be recognized; a
  163.       clear bit means that the corresponding state may be ignored.    A set
  164.       bit in the disallowed shift states word indicates that the
  165.       corresponding shift state must be inactive.
  166.     if bit 2 is set, either control key may be pressed for the hotkey; if
  167.       bits 8 and 10 are both set, then both control keys must be pressed.
  168.       Similarly for bits 3 and 9/11, as well as 7 and 0/1.
  169.     for the disallowed-states word, if one of the "either" bits is set,
  170.       then both the corresponding left bit and right bit must be set
  171.     examples:
  172.         Ctrl-Alt-Del monitoring: 53h 000Ch 0003h 06h
  173.         Alt-key tap (DESQview):  B8h 0000h 0007h 08h
  174.         Shf-Shf-N (NOTE.COM):     31h 0003h 000Ch 00h
  175.  
  176. Bitmask of shift states:
  177.  bit 0: right shift pressed
  178.  bit 1: left shift pressed
  179.  bit 2: either control key pressed
  180.  bit 3: either Alt key pressed
  181.  bit 4: ScrollLock active
  182.  bit 5: NumLock active
  183.  bit 6: CapsLock active
  184.  bit 7: either shift key pressed
  185.  bit 8: left control key pressed
  186.  bit 9: left Alt key pressed
  187.  bit 10: right control key pressed
  188.  bit 11: right Alt key pressed
  189.  bit 12: ScrollLock pressed
  190.  bit 13: NumLock pressed
  191.  bit 14: CapsLock pressed
  192.  bit 15: SysRq key pressed
  193.  
  194. Format of interrupt sharing protocol interrupt handler entry point:
  195. Offset    Size    Description
  196.  00h  2 BYTEs    short jump to actual start of interrupt handler, immediately
  197.         following this data block (EBh 10h)
  198.  02h    DWORD    address of next handler in chain
  199.  06h    WORD    signature 424Bh
  200.  08h    BYTE    EOI flag
  201.         00h software interrupt or secondary hardware interrupt handler
  202.         80h primary hardware interrupt handler (will issue EOI)
  203.  09h  2 BYTEs    short jump to hardware reset routine
  204.         must point at a valid FAR procedure (may be just RETF)
  205.  0Bh  7 BYTEs    reserved (0)
  206.  
  207. Signatures known to be in use:
  208.  'Crynwr  ' 'SPELLER '    TSR spelling-checker
  209.  'heathh  ' 'Monitor '
  210.  'Ralf B  ' 'FASTMOUS'    example TSR included with sample AMIS library code
  211.  'Ralf B  ' 'NOLPT n '    example TSR -- turn LPTn into bit-bucket
  212.  'Ralf B  ' 'NOTE    '    example TSR -- popup note-taker
  213.  'Ralf B  ' 'RBkeyswp'    RBkeyswap v3.0+ -- swap Esc/~ and LCtrl/CapsLock keys
  214.  'Ralf B  ' 'SWITCHAR'    example TSR -- add switchar() support removed from DOS5
  215.  'Ralf B  ' 'VGABLANK'    example TSR -- VGA-only screen blanker
  216.  'TifaWARE' 'EATMEM  '    George A. Theall's public domain memory restrictor for
  217.              testing programs (v1.1+)
  218.         'RECALL  '    public domain commandline editor and history (v1.2+)
  219.  'Todd    ' 'XPTR2   '  PC-to-Transputer interface by Todd Radel
  220.